/*
 * LastError.h
 *
 *  Created on: 2012-12-7
 *      Author: yangentao@gmail.com
 */

#pragma once;
#include <string>
#include <exception>
#include <windows.h>
using namespace std;

namespace yet {

class LastError: public exception {
public:
	LastError();
	virtual ~LastError();
public:
	DWORD getCode();
	string getMessage();
	void print();
private:
	DWORD code;
};

} /* namespace yet */
